using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;

public class DialogPanel : MonoBehaviour
{
    
    // Start is called before the first frame update
    [SerializeField] private Text contentText;
    [SerializeField] private Button confirmButton;

    private void Start()
    {
        confirmButton.onClick.AddListener(OnConfirmButtonClick);
    }

    private void OnConfirmButtonClick()
    {
        this.gameObject.SetActive(false);
    }
    public void Show(string content)
    {
        contentText.text = content;
        this.gameObject.SetActive(true);
    }
}
